package com.xxc.common.config;
import org.springframework.boot.CommandLineRunner;
import org.springframework.stereotype.Component;
/**
 * spring boot 容器加载后自动监听
 */
@Component
public class MyCommandRunner implements CommandLineRunner {
    @Override
    public void run(String... args) {
        //System.out.println("开始自动加载指定的页面");
        try {
            Runtime.getRuntime().exec("cmd   /c   start   http://localhost:10001/admin/login.html");//指定路径
        } catch (Exception ex) {
            ex.printStackTrace();
        }
    }
}